package com.zhang.chatcenter.common.api.authority;

import com.zhang.infrastructure.api.authority.DirectionRemoteVO;
import com.zhang.infrastructure.api.authority.DirectionReqRemoteDTO;
import com.zhang.infrastructure.model.constant.ServerNameConstant;
import com.zhang.chatcenter.common.api.authority.fallback.SystemDirectionRemoteFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import javax.validation.Valid;
import java.util.List;

@FeignClient(value = ServerNameConstant.AUTHORITY_CENTER, path = "/authorityCenter/sysDirection", fallback = SystemDirectionRemoteFallback.class, contextId = "SystemDirectionRemote")
public interface SystemDirectionRemote {
    @RequestMapping(value = "/getDirectionByCodeList", method = RequestMethod.POST)
    List<DirectionRemoteVO> getDirectionByCodeList(@RequestBody @Valid DirectionReqRemoteDTO directionReqExtDTO);
}
